using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._TopographicProductionTools._DataManagement._Features
{
    /// <summary>
    /// <para>Split Features</para>
    /// <para>Splits features on input feature classes for any number of polyline or polygon target feature classes using the cutting features and inserts points on the cutting feature.</para>
    /// <para>使用切割特征对输入要素类上的要素进行分割，以划分任意数量的折线或面目标要素类，并在切割要素上插入点。</para>
    /// </summary>    
    [DisplayName("Split Features")]
    public class SplitFeatures : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public SplitFeatures()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_cutting_features">
        /// <para>Cutting Features</para>
        /// <para>The cutting feature used to split the target features where they intersect the target feature class geometries.</para>
        /// <para>切割特征，用于分割目标要素与目标要素类几何相交的目标要素。</para>
        /// </param>
        /// <param name="_target_features">
        /// <para>Target Features</para>
        /// <para>The features that will be divided by the cutting features.</para>
        /// <para>将除以切割特征的特征。</para>
        /// </param>
        /// <param name="_use_target_z">
        /// <para>Use Target Z Values</para>
        /// <para><xdoc>
        ///   <para>Specifies the source of the z-value from the source or target.</para>
        ///   <bulletList>
        ///     <bullet_item>Checked—Uses the z-value from the source or target.</bullet_item><para/>
        ///     <bullet_item>Unchecked—Does not use the z-value. This is the default.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定源或目标的 z 值的来源。</para>
        ///   <bulletList>
        ///     <bullet_item>选中 （Checked） - 使用源或目标的 z 值。</bullet_item><para/>
        ///     <bullet_item>未选中 - 不使用 z 值。这是默认设置。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// </param>
        public SplitFeatures(object _cutting_features, List<object> _target_features, _use_target_z_value _use_target_z)
        {
            this._cutting_features = _cutting_features;
            this._target_features = _target_features;
            this._use_target_z = _use_target_z;
        }
        public override string ToolboxName => "Topographic Production Tools";

        public override string ToolName => "Split Features";

        public override string CallName => "topographic.SplitFeatures";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_cutting_features, _target_features, _use_target_z.GetGPValue(), _out_feature_layer];

        /// <summary>
        /// <para>Cutting Features</para>
        /// <para>The cutting feature used to split the target features where they intersect the target feature class geometries.</para>
        /// <para>切割特征，用于分割目标要素与目标要素类几何相交的目标要素。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Cutting Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _cutting_features { get; set; }


        /// <summary>
        /// <para>Target Features</para>
        /// <para>The features that will be divided by the cutting features.</para>
        /// <para>将除以切割特征的特征。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Target Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public List<object> _target_features { get; set; }


        /// <summary>
        /// <para>Use Target Z Values</para>
        /// <para><xdoc>
        ///   <para>Specifies the source of the z-value from the source or target.</para>
        ///   <bulletList>
        ///     <bullet_item>Checked—Uses the z-value from the source or target.</bullet_item><para/>
        ///     <bullet_item>Unchecked—Does not use the z-value. This is the default.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定源或目标的 z 值的来源。</para>
        ///   <bulletList>
        ///     <bullet_item>选中 （Checked） - 使用源或目标的 z 值。</bullet_item><para/>
        ///     <bullet_item>未选中 - 不使用 z 值。这是默认设置。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Use Target Z Values")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public _use_target_z_value _use_target_z { get; set; }

        public enum _use_target_z_value
        {
            /// <summary>
            /// <para>USE_TARGET_Z</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("USE_TARGET_Z")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>DONT_USE_TARGET_Z</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("DONT_USE_TARGET_Z")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Output Features</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Features")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_feature_layer { get; set; }


        public SplitFeatures SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}